import Vue from 'vue'
import VueRouter from 'vue-router'
import login from '../components/login/login'
import home from '../components/home/home'
import welcome from '../components/home/welcome'
import manager from '../components/Administration/manager'
import role from '../components/Administration/role'
Vue.use(VueRouter)

const routes = [
  {
    path: '/login',
    component: login
  }, {
    redirect: '/login',
    path: '/'
  },
  {
    path: '/home',
    component: home,
    children: [
      {
        path: '/home/welcome',
        component: welcome
      },
      {
        path: '/home/manager',
        component: manager
      },
      {
        path: '/home/role',
        component: role
      }
    ]
  }
]

const router = new VueRouter({
  routes
})

export default router
